package com.lxj.student_security.mapper;

import com.lxj.student_security.entity.Permission;
import com.lxj.student_security.entity.User;
import com.lxj.student_security.entity.vo.UserRoleRelation;

import java.util.List;

public interface UserMapper {
    User selectOne(String username);

    List<Permission> getPermissionsByUserId(Integer id);

    User getByName(String username);

    List<User> findAll(User user);

    int add(User user);

    int delete(Integer[] id);

    List<UserRoleRelation> findRole(Integer id);

    int addRole(UserRoleRelation urr);

    void updateUserType(UserRoleRelation urr);

    int deleteRole(UserRoleRelation urr);

    Integer findId(String username);
}
